﻿<Window x:Class="FeedNews.MainWindow"
        xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
        xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
        DataContext="{Binding Main, Source={StaticResource MainViewLocator}}"
        Title="FeedNews - Desktop"  WindowStartupLocation="CenterScreen"
        Height="{Binding mainWindowHeight, Mode=TwoWay, Source={StaticResource MainViewLocator}}" 
        Width="{Binding mainWindowWidth , Mode=TwoWay, Source={StaticResource MainViewLocator}}"
        MaxHeight="{Binding mainMaxHeight, Source={StaticResource MainViewLocator}}" 
        MaxWidth="{Binding mainMaxWidth, Source={StaticResource MainViewLocator}}">
    <Grid Background="Black">
        <Grid.ColumnDefinitions>
            <ColumnDefinition Width="Auto" />
            <ColumnDefinition Width="{Binding ViewWidth}" />
        </Grid.ColumnDefinitions>
        <!-- Menu -->
        <Grid  Grid.Column="0" 
               Background="#FF303030" >
            <StackPanel>
                <Button 
                    Style="{DynamicResource IconButtonStyle}"
                    Margin="10"
                    Width="{Binding IconWidth,Mode=TwoWay,Source={StaticResource MainViewLocator}}"
                    Command="{Binding ViewRSSFeedCommand}">
                    <Image Source="Icon/rss.png">

                    </Image>
                </Button>
                <Button 
                    Style="{DynamicResource IconButtonStyle}"
                    Margin="10" 
                    Width="{Binding IconWidth,Mode=TwoWay,Source={StaticResource MainViewLocator}}"
                    Command="{Binding SettingViewCommand}">
                    <Image Source="Icon/processing.png">
                    </Image>
                </Button>
                <Button 
                    Style="{DynamicResource IconButtonStyle}"
                    Margin="10" 
                    Width="{Binding IconWidth,Mode=TwoWay,Source={StaticResource MainViewLocator}}"
                    Command="{Binding SearchRSSViewCommand}">
                    <Image Source="Icon/search.png">
                    </Image>
                </Button>
            </StackPanel>
        </Grid>
        <!-- Content-->
        <Grid  Grid.Column="1">
            <ContentControl Content="{Binding CurrentViewModel}"/>
        </Grid>

    </Grid>
</Window>

